Create Custom Algorithm for a Data Analytics Job
When you create a data analytics job, you can either use a predefined algorithm or a custom algorithm, depending on your use case.
To create a custom algorithm
-
Click +Algorithm and provide the following information:
-
Algorithm Type- Select Custom to create a custom algorithm for the data analytics job.
-
Algorithm Name - Provide a unique name for the algorithm.
-
Column Name (Optional) - Select the column on which to apply the selected algorithm. This field is optional when adding a custom algorithm.
Note:
Ensure that the selected column contains binary data only.
-
Source (Optional) - Select the source file or table containing the column on which the algorithm will be applied. This field is optional when adding a custom algorithm.
-
Target (Optional) - Select the file or table where the output of the algorithm will be stored. You can either choose an existing file or table or create a new one. This field is optional when adding a custom algorithm.
-
Click Add.
-
After you click Add, the Creation Status displays the following types of statuses depending on whether the data analytics job for the selected algorithm is created or not:
-
In Progress - when the job is being created.
-
Success - when the job is created successfully.
-
Failed - when the job creation fails.
-
-
To add code to the custom algorithm, click the algorithm name. You are navigated to JupyterLab Notebook.
-
In the JupyterLab Notebook, a sample custom code is added. based on the source and target selected for the custom algorithm job. Replace the sample code and other details like filename and so on with your custom code.
The Read Data section is related to the source files or tables. Replace the path with the actual path of source data.
The Write Data section is related to the target files or tables.
-
To visualize the data from a custom algorithm
-
Uncomment the section of the code starting with the
import pickle
statement. -
Ensure that you use the exact path specified in the above line of code for the pickle file.
What's next? Data Analytics using Python with JupyterLab |